import { createRouter, createWebHistory ,createWebHashHistory} from 'vue-router'
import HomeView from '../views/HomeView.vue'


const router = createRouter({
  // history: createWebHistory(import.meta.env.BASE_URL),
  history:createWebHashHistory(),
  routes: [

    // {
    //   path: '/about',
    //   name: 'about',
    //   // route level code-splitting
    //   // this generates a separate chunk (About.[hash].js) for this route
    //   // which is lazy-loaded when the route is visited.
    //   component: () => import('../views/AboutView.vue'),
    // },
    {
      path: '/',
      name: 'Login',
      component: () => import('../views/LoginView.vue'),
      meta: { title: '登录' }
    },
    {
      path: '/Main',
      name: 'Main',
      component: () => import('../views/MainView.vue'),
      meta: { title: '主页' },
      redirect: '/home',
      children: [
        {
          path: '/home',
          name: 'home',
          component: () => import('../views/HomeView.vue'),
          meta: { title: '首页' }
        },
        {
          path: '/GetProdut',
          name: 'GetProdut',
          component: () => import('../views/Product/GetProdutView.vue'),
          meta: { title: '货品列表' }
        },
        {
          path: '/CreateProdut',
          name: 'CreateProdut',
          component: () => import('../views/Product/CreateProductView.vue'),
          meta: { title: '新增货品' }
        },
        {
          path: '/ProductDetail',
          name: 'ProductDetail',
          component: () => import('../views/Product/ProductDetailView.vue'),
          meta: { title: '货品详情' }
        },
        {
          path: '/GetProductType',
          name: 'GetProductType',
          component: () => import('../views/Product/GetProductTypeView.vue'),
          meta: { title: '货品类型' }
        },
        {
          path: '/GetUnit',
          name: 'GetUnit',
          component: () => import('../views/Unit/GetUnitView.vue'),
          meta: { title: '单位列表' }
        },
        {
          path: '/GetInventory',
          name: 'GetInventory',
          component: () => import('../views/Inventory/GetInventoryView.vue'),
          meta: { title: '库存列表' }
        },
        {
          path: '/GetWarehouse',
          name: 'GetWarehouse',
          component: () => import('../views/Warehouse/GetWarehouseView.vue'),
          meta: { title: '仓库列表' }
        },
        {
          path: '/GetStoragelocation',
          name: 'GetStoragelocation',
          component: () => import('../views/Storagelocation/GetStoragelocationView.vue'),
          meta: { title: '库区列表' }
        },
        {
          path: '/GetWarePosition',
          name: 'GetWarePosition',
          component: () => import('../views/WarePosition/GetWarePositionView.vue'),
          meta: { title: '仓位列表' }
        },
        {
          path: '/GetWarehousing',
          name: 'GetWarehousing',
          component: () => import('../views/Warehousing/GetWarehousingView.vue'),
          meta: { title: '入库列表' }
        },
        {
          path: '/GetInOutFlow',
          name: 'GetInOutFlow',
          component: () => import('../views/InOutFlow/GetInOutFlowView.vue'),
          meta: { title: '出入库流水' }
        },
        {
          path: '/GetInboundFlow',
          name: 'GetInboundFlow',
          component: () => import('../views/InOutFlow/GetInboundFlowView.vue'),
          meta: { title: '入库流水' }
        },
        {
          path: '/GetOutboundFlow',
          name: 'GetOutboundFlow',
          component: () => import('../views/InOutFlow/GetOutboundFlowView.vue'),
          meta: { title: '出库流水' }
        },
        {
          path: '/UpdateWarehouse',
          name: 'UpdateWarehouse',
          component: () => import('../views/Warehouse/UpdateWarehouseView.vue'),
          meta: { title: '仓库编辑' }
        },
        {
          path: '/CreateWarehousing',
          name: 'CreateWarehousing',
          component: () => import('../views/Warehousing/CreateWarehousingView.vue'),
          meta: { title: '新增入库单' }
        },
        {
          path: '/DetailWarehousing',
          name: 'DetailWarehousing',
          component: () => import('../views/Warehousing/DetailWarehousingView.vue'),
          meta: { title: '入库单详情' }
        },
        {
          path: '/CreateWarehouse',
          name: 'CreateWarehouse',
          component: () => import('../views/Warehouse/CreateWarehouseView.vue'),
          meta: { title: '新增仓库' }
        },
        {
          path: '/DetailWarehouse',
          name: 'DetailWarehouse',
          component: () => import('../views/Warehouse/DetailWarehouseView.vue'),
          meta: { title: '仓库详情' }
        },
        {
          path: '/GetSupplier',
          name: 'GetSupplier',
          component: () => import('../views/Supplier/GetSupplierView.vue'),
          meta: { title: '供应商列表' }
        },
        {
          path: '/CreateSupplier',
          name: 'CreateSupplier',
          component: () => import('../views/Supplier/CreateSupplierView.vue'),
          meta: { title: '新增供应商' }
        },
        {
          path: '/DetailSupplier',
          name: 'DetailSupplier',
          component: () => import('../views/Supplier/DetailSupplier.vue'),
          meta: { title: '供应商详情' }
        },

        {
          path: '/GetCustomer',
          name: 'GetCustomer',
          component: () => import('../views/Customer/GetCustomerView.vue'),
          meta: { title: '客户列表' }
        },
        {
          path: '/GetUser',
          name: 'GetUser',
          component: () => import('../views/Enterprise/GetUserView.vue'),
          meta: { title: '用户管理' }
        },
        {
          path: '/Position',
          name: 'Position',
          component: () => import('../views/Enterprise/GetPositionView.vue'),
          meta: { title: '岗位管理' }
        },
        {
          path: '/Organization',
          name: 'Organization',
          component: () => import('../views/Enterprise/GetOrganizationView.vue'),
          meta: { title: '组织管理' }
        },
        {
          path: '/Roles',
          name: 'Roles',
          component: () => import('../views/Enterprise/GetRoleView.vue'),
          meta: { title: '角色管理' }
        },
        {
          path: '/Permission',
          name: 'Permission',
          component: () => import('../views/Enterprise/GetPermissionView.vue'),
          meta: { title: '权限管理' }
        },
        {
          path: '/PersonalSettings',
          name: 'PersonalSettings',
          component: () => import('../views/Profile/PersonalSettings.vue'),
          meta: { title: '个人设置' }
        },
        {
          path: '/UpdateSupplier',
          name: 'UpdateSupplier',
          component: () => import('../views/Supplier/UpdateSupplier.vue'),
          meta: { title: '编辑供应商' }
        },
        {
          path: '/GetDrift',
          name: 'GetDrift',
          component: () => import('../views/Drift/GetDriftView.vue'),
          meta: { title: '巷道列表' }
        },
        {
          path: '/GetPlatform',
          name: 'GetPlatform',
          component: () => import('../views/Platform/GetPlatformView.vue'),
          meta: { title: '站台列表' }
        },

        {
          path: '/CreateCustomer',
          name: 'CreateCustomer',
          component: () => import('../views/Customer/CreateCustomerView.vue'),
          meta: { title: '新增客户' }
        },
        {
          path: '/UpdateCustomer',
          name: 'UpdateCustomer',
          component: () => import('../views/Customer/UpdateCustomerView.vue'),
          meta: { title: '编辑客户' }
        },
        {
          path: '/DetailCustomer',
          name: 'DetailCustomer',
          component: () => import('../views/Customer/DetailCustomerView.vue'),
          meta: { title: '客户详情' }
        },
        {
          path: '/GetInformation',
          name: 'GetInformation',
          component: () => import('../views/Information/GetInformationView.vue'),
          meta: { title: '消息管理' }
        },
        {
          path: '/GetNumberingRule',
          name: 'GetNumberingRule',
          component: () => import('../views/Settings/GetNumberingRuleView.vue'),
          meta: { title: '编号规则' }
        },
        {
          path: '/GetSalesOrder',
          name: 'GetSalesOrder',
          component: () => import('../views/SalesOrders/GetSalesOrderView.vue'),
          meta: { title: '销售订单列表' }
        },
        {
          path: '/GetStockingGoods',
          name: 'GetStockingGoods',
          component: () => import('../views/StockingGoods/GetStockingGoodsView.vue'),
          meta: { title: '进货订单列表' }
        },
        {
          path: '/CreateStockingGoods',
          name: 'CreateStockingGoods',
          component: () => import('../views/StockingGoods/CreateStockingGoodsView.vue'),
          meta: { title: '新增进货订单' }
        },
        {
          path: '/UpdateStockingGoods',
          name: 'UpdateStockingGoods',
          component: () => import('../views/StockingGoods/UpdateStockingGoodsView.vue'),
          meta: { title: '编辑进货订单' }
        },
        {
          path: '/DetailStockingGoods',
          name: 'DetailStockingGoods',
          component: () => import('../views/StockingGoods/DetailStockingGoodsView.vue'),
          meta: { title: '进货订单详情' }
        },
        {
          path: '/GetDictionary',
          name: 'GetDictionary',
          component: () => import('../views/Dictionary/GetDictionary.vue'),
          meta: { title: '字典管理' }
        },
        {
          path: '/GetTray',
          name: 'GetTray',
          component: () => import('../views/Tray/GetTrayView.vue'),
          meta: { title: '托盘列表' }
        },
        {
          path: '/GetOutbound',
          name: 'GetOutbound',
          component: () => import('../views/Outbound/GetOutboundView.vue'),
          meta: { title: '出库列表' }
        },
        {
          path: '/CreateOutbound',
          name: 'CreateOutbound',
          component: () => import('../views/Outbound/CreateOutboundView.vue'),
          meta: { title: '新增出库单' }
        },
        {
          path: '/DetailOutbound',
          name: 'DetailOutbound',
          component: () => import('../views/Outbound/DetailOutboundView.vue'),
          meta: { title: '出库单详情' }
        },
        {
          path: '/GetSalesOrder',
          name: 'GetSalesOrder',
          component: () => import('../views/SalesOrders/GetSalesOrderView.vue'),
          meta: { title: '销售订单' }
        },
        {
          path: '/createSalesOrder',
          name: 'createSalesOrder',
          component: () => import('../views/SalesOrders/CreateSalesOrderView.vue'),
          meta: { title: '新增销售订单' }
        },
        {
          path: '/StockCount',
          name: 'StockCount',
          component: () => import('../views/Statistics/GetStockCountView.vue'),
          meta: { title: '进货统计' }
        },
        {
          path: '/updateSalesOrder',
          name: 'updateSalesOrder',
          component: () => import('../views/SalesOrders/UpdateSalesOrderView.vue'),
          meta: { title: '编辑销售订单' }
        },
        {
          path: '/detailSalesOrder',
          name: 'detailSalesOrder',
          component: () => import('../views/SalesOrders/DetailSalesOrderView.vue'),
          meta: { title: '销售订单详情' }
          },
          {
          path: '/StockCount',
          name: 'StockCount',
          component: () => import('../views/Statistics/GetStockCountView.vue'),
          meta: { title: '进货统计' }
        },
        {
          path: '/GetShelf',
          name: 'GetShelf',
          component: () => import('../views/Shelf/GetShelfView.vue'),
          meta: { title: '货架列表' }
        },
        {
          path: '/GetInventoryCount',
          name: 'GetInventoryCount',
          component: () => import('../views/InventoryCount/GetInventoryCountView.vue'),
          meta: { title: '盘点列表' }
        },
        {
          path: '/InventoryWarning',
          name: 'InventoryWarning',
          component: () => import('../views/Inventory/InventoryWarningView.vue'),
          meta: { title: '库存预警' }
        },
        {
          path: '/DetailInventoryCount',
          name: 'DetailInventoryCount',
          component: () => import('../views/InventoryCount/DetailInventoryCountView.vue'),
          meta: { title: '盘点详情' }
        },
        {
          path: '/InOutType',
          name: 'InOutType',
          component: () => import('../views/InOutType/GetInOutTypeView.vue'),
          meta: { title: '出入库类型' }
        },
        {
          path: '/SaleCount',
          name: 'SaleCount',
          component: () => import('../views/Statistics/GetSaleCountView.vue'),
          meta: { title: '销售统计' }
        }, 
          {
            path:'/getgoodsreturn',
            name: 'getgoodsreturn',
            component: () => import('../views/GoodsReturns/GetGoodsReturnsView.vue'),
            meta: { title: '进货退货列表' }
          },
          {
            path:'/creategoodsreturn',
            name: 'creategoodsreturn',
            component: () => import('../views/GoodsReturns/CreateGoodsReturnsView.vue'),
            meta: { title: '新增进货退货' }
          },
          {
            path:'/updategoodsreturn',
            name: 'updategoodsreturn',
            component: () => import('../views/GoodsReturns/UpdateGoodsReturnsView.vue'),
            meta: { title: '编辑进货退货' }
          },
          {
            path:'/detailgoodsreturn',
            name: 'detailgoodsreturn',
            component: () => import('../views/GoodsReturns/DetailGoodsReturnsView.vue'),
            meta: { title: '进货退货详情' }
          },
          {
            path:'/getsalereturn',
            name: 'getsalereturn',
            component: () => import('../views/SaleReturns/GetSaleReturnsView.vue'),
            meta: { title: '销售退货列表' }
          },
          {
            path:'/createsalereturn',
            name: 'createsalereturn',
            component: () => import('../views/SaleReturns/CreateSaleReturnsView.vue'),
            meta: { title: '新增销售退货' }
          },
        {
          path: '/getgoodsreturn',
          name: 'getgoodsreturn',
          component: () => import('../views/GoodsReturns/GetGoodsReturnsView.vue'),
          meta: { title: '进货退货列表' }
        },
        {
          path: '/creategoodsreturn',
          name: 'creategoodsreturn',
          component: () => import('../views/GoodsReturns/CreateGoodsReturnsView.vue'),
          meta: { title: '新增进货退货' }
        },
        {
          path: '/updategoodsreturn',
          name: 'updategoodsreturn',
          component: () => import('../views/GoodsReturns/UpdateGoodsReturnsView.vue'),
          meta: { title: '编辑进货退货' }
        },
        {
          path: '/detailgoodsreturn',
          name: 'detailgoodsreturn',
          component: () => import('../views/GoodsReturns/DetailGoodsReturnsView.vue'),
          meta: { title: '进货退货详情' }
        },
        {
          path: '/getsalereturn',
          name: 'getsalereturn',
          component: () => import('../views/SaleReturns/GetSaleReturnsView.vue'),
          meta: { title: '销售退货列表' }
        },
        {
          path: '/createsalereturn',
          name: 'createsalereturn',
          component: () => import('../views/SaleReturns/CreateSaleReturnsView.vue'),
          meta: { title: '新增销售退货' }
        },
        {
          path: '/GetTransfer',
          name: 'GetTransfer',
          component: () => import('../views/Transfer/GetTransferView.vue'),
          meta: { title: '调拨列表' }
        },
        {
          path: '/CreateTransfer',
          name: 'CreateTransfer',
          component: () => import('../views/Transfer/CreateTransferView.vue'),
          meta: { title: '新增调拨单' }
        },
        {
          path: '/UpdateTransfer',
          name: 'UpdateTransfer',
          component: () => import('../views/Transfer/CreateTransferView.vue'),
          meta: { title: '编辑调拨单' }
        },
        {
          path: '/DetailTransfer',
          name: 'DetailTransfer',
          component: () => import('../views/Transfer/DetailTransferView.vue'),
          meta: { title: '调拨单详情' }
        },

          {
            path:'/updatesalereturn',
            name: 'updatesalereturn',
            component: () => import('../views/SaleReturns/UpdateSalesReturnsView.vue'),
            meta: { title: '编辑销售退货' }
          },
          {
            path:'/detailsalereturn',
            name: 'detailsalereturn',
            component: () => import('../views/SaleReturns/DetailSaleReturnsView.vue'),
            meta: { title: '销售退货详情' }
          },
          {
            path:'/detailsalereturn',
            name: 'detailsalereturn',
            component: () => import('../views/SaleReturns/DetailSaleReturnsView.vue'),
            meta: { title: '销售退货详情' }
          },
        {
          path: '/GetShelf',
          name: 'GetShelf',
          component: () => import('../views/Shelf/GetShelfView.vue'),
          meta: { title: '货架列表' }
        },
        {
          path: '/GetInventoryCount',
          name: 'GetInventoryCount',
          component: () => import('../views/InventoryCount/GetInventoryCountView.vue'),
          meta: { title: '盘点列表' }
           },
        {
          path: '/GetInventoryCountStatistics',
          name: 'GetInventoryCountStatistics',
          component: () => import('../views/InventoryCount/GetInventoryCountStatisticsView.vue'),
          meta: { title: '盘点统计' }
        },
        {
          path: '/CreateInventoryCount',
          name: 'CreateInventoryCount',
          component: () => import('../views/InventoryCount/CreateInventoryCountView.vue'),
          meta: { title: '新增盘点' }
        },
        {
          path: '/DetailInventoryCount',
          name: 'DetailInventoryCount',
          component: () => import('../views/InventoryCount/DetailInventoryCountView.vue'),
          meta: { title: '盘点详情' }
        },
        {
          path: '/InOutType',
          name: 'InOutType',
          component: () => import('../views/InOutType/GetInOutTypeView.vue'),
          meta: { title: '出入库类型' }
        },
        {
          path: '/SaleCount',
          name: 'SaleCount',
          component: () => import('../views/Statistics/GetSaleCountView.vue'),
          meta: { title: '销售统计' }
        },
          {
            path:'/getgoodsreturn',
            name: 'getgoodsreturn',
            component: () => import('../views/GoodsReturns/GetGoodsReturnsView.vue'),
            meta: { title: '进货退货列表' }
          },
          {
            path:'/creategoodsreturn',
            name: 'creategoodsreturn',
            component: () => import('../views/GoodsReturns/CreateGoodsReturnsView.vue'),
            meta: { title: '新增进货退货' }
          },
          {
            path:'/updategoodsreturn',
            name: 'updategoodsreturn',
            component: () => import('../views/GoodsReturns/UpdateGoodsReturnsView.vue'),
            meta: { title: '编辑进货退货' }
          },
          {
            path:'/detailgoodsreturn',
            name: 'detailgoodsreturn',
            component: () => import('../views/GoodsReturns/DetailGoodsReturnsView.vue'),
            meta: { title: '进货退货详情' }
          },
          {
            path:'/getsalereturn',
            name: 'getsalereturn',
            component: () => import('../views/SaleReturns/GetSaleReturnsView.vue'),
            meta: { title: '销售退货列表' }
          },
          {
            path:'/createsalereturn',
            name: 'createsalereturn',
            component: () => import('../views/SaleReturns/CreateSaleReturnsView.vue'),
            meta: { title: '新增销售退货' }
          },
      ]
    }
  ],
})

export default router
